package com.atguigu.feign.config;


import com.atguigu.common.CommonResult;
import com.atguigu.entity.Payment;
import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@Component
@FeignClient(value="CLOUD-PROVIDER-SERVICE")
public interface ProviderClient {
    @LoadBalanced
    @GetMapping("/edu/payment/selectById/{id}")
    public CommonResult<Payment> selectById(@PathVariable("id") Long id);
    @GetMapping(value = "/edu/payment/payment/feign/timeout")
    public String paymentFeignTimeout();
}
